<%@ page language="java" pageEncoding="UTF-8" %>
<html>
<head>
	<jsp:include page="/WEB-INF/jsp/ApnsHeader.jsp" />
	<script type="text/javascript">
	function doSaveMember() {
		APNS.util.doAjax({
			url: APNS.context.getContextPath() + "/propertySet/memberSave.sd",
			data: {
				userId: APNS.util.getFormValue("memberForm", "userId"),
				userPw: APNS.util.getFormValue("memberForm", "userPw"),
				userName: APNS.util.getFormValue("memberForm", "userName"),
				userEmail: APNS.util.getFormValue("memberForm", "userEmail")
			},
			complete: function(req, status) {
				var response = eval("(" + req.responseText + ")");
				if( response.result == "success")
				{
					alert("등록완료!");
					document.location.href = APNS.context.getContextPath() + "/page.sd?viewName=ApnsMemberJoin";
				}
			}
		});
	}
	
	$(document).ready(function(){
		$("#buttonMemberSave").click(function(){
			doSaveMember();
		});
	});
	</script>
</head>
<body>
<jsp:include page="/WEB-INF/jsp/ApnsTopInfo.jsp" />
<ul>
	<li>Member Join</li>
</ul>
<form id="memberForm">
	<ul>
		<li>아이디 : <input type="text" name="userId" /></li>
		<li>암호 : <input type="password" name="userPw" /></li>
		<li>이름 : <input type="text" name="userName" /></li>
		<li>이메일 : <input type="text" name="userEmail" /></li>
	</ul>
	<p>
		<input type="button" id="buttonMemberSave" value="등록" />
	</p>
</form>

</body>
</html>